Automated data storage libraries are known for providing cost effective storage and retrieval of large quantities of data. Automated data storage libraries provide a means for storing data on data storage media that are not permanently mounted in data storage drives, and that are stored on storage shelves inside the library. One or more robot accessors retrieve selected data storage media from storage shelves and provide them to data storage drives. Host computers communicate with the automated data storage library through control paths. A control path is a communication interface that comprises library control commands or signals. The control path interface may comprise serial interfaces such as RS-232, SCSI (Small Computer Systems Interface), FC-AL (Fibre Channel-Arbitrated Loop), etc. In certain system configurations, a host may include multiple host bus adapters (HBAs) that provide multiple physical paths to a device, such as a dual ported tape device. Each of these physical paths could function as one or more control paths. If a host application, such as a data backup application or device driver, is sending commands to an automated data storage library using a control path and the control path experiences a failure, such as a permanent path error (e.g., a failure in the HBA or cable), then the application would cease operating down the failed path. In such a case, failover procedures may be invoked either by a system administrator or automatically by the host computer to either restart the application, or reissue the command, down an alternate path.
If the host computer restarts the application, then any operations performed by the library prior to the failure may be lost. This can create large delays because the application may have to repeat work that may have already been completed. If the host computer reissues the command down an alternate path without knowing if the previous command sent to the automated data storage library was successfully completed then errors may occur. For example, a host computer may encounter a loss of library communication while moving media between a storage slot and a drive. The host computer may not be able to determine if the command completed successfully because there was no response from the automated data storage library to the command. If the host computer retries the same command then it may fail because the library has already successfully completed the command. In other situations, the command retry may cause the cartridge to be moved away from its intended destination if the library has successfully completed an exchange command. For these reasons, there is a need in the art for improved techniques for managing failover operations for automated data storage libraries.